> # Casino Slot Machine Game --- #### Slot machines include one or more currency detectors that validate the form of payment, whether coin, cash, voucher, or token. The machine pays out according to the pattern of symbols displayed when the reels stop "spinning". **--> Here We will be using *emogies* in place of currency.** ___ ## How to make the **Casino Slot Machine** game :-> >Technologies used: *html, CSS, simple JS* > ## Our Game Looks like-> ---

## **Approach :**

> In 1st Div 3 slots are proived with some initial emogies . ```html
😂
😍
😎
``` > In 2nd Div We have 3 elements:
1. **Controller which take input from 1 to 10 , decides the spped of changes of emogies**
2. **START button**
3. **STOP button** ```html
``` > Last Div to show result = i) If you are winning ii) OR you are loosing ```html

Hey! You are Rocking 😎🔥

``` --- ## **-->*How Buttons , speed -controller and Output works ??*** >### 'START BUTTON' :: ```html ``` ** Clicking On 'START' button starclick() function Works. ```js function startclick(){ updateAnimation(inpSpeed.value) value1.classList.add('animation') value2.classList.add('animation') value3.classList.add('animation') myoutput.textContent = 'Hey! You are ON 😎🔥' } ``` --- > ### Speed-Controller: Take input between from 1 to 10 and decrease and increase the speed. ```html ``` ```js inpSpeed.onchange= function(ev){ document.documentElement.style.setProperty('--speed', ev.target.value) updateAnimation(ev.target.value) } ``` --- > ### ***STOP BUTTON:*** ```html ``` ->Clicking on STOP Button, stop the game and display the result in below div. **How JS Works behind It** ```js function stopclick(){ clearInterval(animationId); console.log("stop button clicked") if(value1.innerText==value2.innerText && value2.innerText==value3.innerText){ text = ' Well Done Boss , You Won! 😎😎😎' }else{ text = ' OOPS!😐 Give it another try ' } ``` > If on the time when emogies of all 3 slots are equal as -> You will win the game, and as a display there will be shown **Well Done Boss , You won!** else , You will loose and will get to be shown that **OOPS! Give another try** --- ># **Demo Video**